import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
/*eslint-disable*/
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import baseConfig from './baseConfig'

const {appName, baseUrl, userId, processEnv} = baseConfig
import {init} from '../runningSDK'
console.log("baseUrl", baseUrl)
import http from "./utils/http"

Vue.prototype.$http = http;
Vue.config.productionTip = false

console.log("process.env.VUE_APP_IDprocess.env.VUE_APP_ID",  process.env.VUE_APP_ID)


// console.log("00000")
init({
  appId: process.env.VUE_APP_ID,
  appName,
  userId,
  processEnv,
  reportUrl: `${baseUrl}/api/error/report`, // 请求的后端地址
  delay: 0, // 延时上报的时间
  errorReport: true, // 是否开启错误监控
})

// console.log(na)
Vue.use(ElementUI);

const app = new Vue({
  router,
  store,

  render: h => h(App)
});

app.$mount('#app')


try {
  console.log(a)
} catch(e) {
  console.log(e)
  throw new Error('普通js报错事例，development 模式请关闭！！！')
}
